                        <? 
                            $frmtime = time();
                            $filterdata["frmtime"] = $frmtime; 
                            $dgdata["frmtime"] = $frmtime; 
                        ?>
                        <div id="contentcontainer">
                            <div class="main">
                                <h3 class="title"><?=$clabel?> &raquo; <?=$mlabel?></h3>
                                <div class="formdiv">                                    
                                        <table width="100%" class="test">
                                            <? if( isset($errors) ) {
                                               foreach($errors as $error) {
                                               ?>
                                            <tr>
                                                <td class="errormsg" colspan="3">
                                                    <?=$error?>    
                                                </td>
                                            </tr>   
                                               <? 
                                               } 
                                            }  ?>
                                            <? if( isset($successes) ) {
                                               foreach($successes as $success) {
                                               ?>
                                            <tr>
                                                <td class="successmsg" colspan="3">
                                                    <?=$success?>    
                                                </td>
                                            </tr>   
                                               <? 
                                               } 
                                            }  
                                            if( isset($filterdata) && $filterdata != "") {
                                            ?>
                                            <tr>
                                                <td colspan="3">
                                                    
                                                    <?
                                                    //print_object($filterdata); exit;
                                                    $this->load->view('elements/filter',$filterdata);
                                                    ?>                            
                                                </td>                                                
                                            </tr>
                                            <?
                                            }
                                            ?>
                                        </table>                                	
                                 </div>
                                <?
                                  //print_object($dgdata); exit;
                                  if(isset($dgdata)) {
                                        if(isset($sdname)) {
                                ?>
                                <div class="actionbar">
                                    <a href="javascript:export_data('<?=$sdname?>','<?=$exporturl?>'); void(0);" title="Export to Excel"><img src="/images/excel.png"/></a>
                                    <a href="javascript:print_data('<?=$sdname?>','<?=$printurl?>'); void(0);" title="Print"><img src="/images/print.png"/></a>
                                </div>
                                <?
                                        }
        						      $this->load->view('elements/datagrid',$dgdata);
                                  }
        						?>   
                            </div>
                        </div>            